﻿<Serializable()> _
    Public Class ServerFile
    Sub New()
        'do nothing
    End Sub
    Sub New(ByVal Fi As FileInfo)
        _FileID = Fi.GetHashCode
        _FileName = Fi.Name
        _OrigFileName = Fi.Name
        _FullPath = Fi.FullName.Replace("\" & Fi.Name, "\")
        _URLPath = _FullPath.Replace(FileTree.PathName, "").Replace("\", "/")
        _CreationDate = Fi.CreationTime
        _ModifiedDate = Fi.LastWriteTime
        _Size = Fi.Length
    End Sub
    Private _FileID As Integer
    Private Property FileID() As Integer
        Get
            Return _FileID
        End Get
        Set(ByVal value As Integer)
            _FileID = value
        End Set
    End Property
    Private _FileName As String
    Public Property FileName() As String
        Get
            Return _FileName
        End Get
        Set(ByVal value As String)
            _FileName = value
        End Set
    End Property
    Private _OrigFileName As String
    Public Property OrigFileName() As String
        Get
            Return _OrigFileName
        End Get
        Set(ByVal value As String)
            _OrigFileName = value
        End Set
    End Property
    Private _FullPath As String
    Public Property FullPath() As String
        Get
            Return _FullPath
        End Get
        Set(ByVal value As String)
            _FullPath = value
        End Set
    End Property
    Private _URLPath As String
    Public Property URLPath() As String
        Get
            Return _URLPath
        End Get
        Set(ByVal value As String)
            _URLPath = value
        End Set
    End Property
    Private _CreationDate As Date
    Public Property CreationDate() As Date
        Get
            Return _CreationDate
        End Get
        Set(ByVal value As Date)
            _CreationDate = value
        End Set
    End Property
    Private _ModifiedDate As Date
    Public Property ModifiedDate() As Date
        Get
            Return _ModifiedDate
        End Get
        Set(ByVal value As Date)
            _ModifiedDate = value
        End Set
    End Property
    Private _Size As Long
    Public Property Size() As Long
        Get
            Return _Size
        End Get
        Set(ByVal value As Long)
            _Size = value
        End Set
    End Property
End Class